package 多态;

public class AnimalDemo {
    /*
    public void useAnimal(Cat c){
        c.eat();
    }
    public void useAnimal(dog d){
        d.eat();
    }
    */
    public void useAnimal(Animal a){
        //Animal a=new Cat();
        //Animal a=new dag();
        a.eat();
    }
}
